-- GENERATED SPELL FOR [Guzzling Patron] --


function spell0_9547(pUnit, Event) --@Curse of Agony,n/a--
pUnit:FullCastSpellOnTarget(14868,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_9547', 30000, 1)
end

function spell1_9547(pUnit, Event) --@Shadow Bolt,n/a--
pUnit:FullCastSpellOnTarget(20825,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_9547', 3000, 1)
end

function Sorts_9547(pUnit, Event)
local choix_sorts_9547 = math.random(0, 1)
if choix_sorts_9547 == 0 then
pUnit:RegisterEvent('spell0_9547', 1, 1)
end
if choix_sorts_9547 == 1 then
pUnit:RegisterEvent('spell1_9547', 1, 1)
end
end

function mob9547_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_9547', math.random(1500, 3000), 1)
end

function mob9547_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob9547_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob9547_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(9547, 1, 'mob9547_Action')
RegisterUnitEvent(9547, 2, 'mob9547_Leave')
RegisterUnitEvent(9547, 3, 'mob9547_Kill')
RegisterUnitEvent(9547, 4, 'mob9547_Die')
